﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Template.Master" AutoEventWireup="true"
    CodeBehind="Fabrica.aspx.cs" Inherits="CDSBDemandControl.View.Web.PaginasInternas.Fabrica" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <div class="divBloco">
        <div class="divEsquerda">
            <div class="FiltroProjeto" runat="server" id="DivFiltroProjeto">
                <table id="TblFiltro" runat="server" cellpadding="0" cellspacing="0" border="0">
                    <tr id="Tr1" runat="server">
                        <td>
                            <span id="spanFiltroFabrica" runat="server" class="spanFiltro">
                                <asp:Label ID="LblComboFabrica" AssociatedControlID="CmbFiltroFabrica" Text="Fornecedor"
                                    runat="server"></asp:Label>
                                <asp:DropDownList runat="server" ID="CmbFiltroFabrica" OnSelectedIndexChanged="CmbFiltro_SelectedIndexChanged"
                                    AutoPostBack="true">
                                    <asp:ListItem Text="Todos" Value="Todos"></asp:ListItem>
                                    <asp:ListItem Text="7COMm" Value="7COMm"></asp:ListItem>
                                    <asp:ListItem Text="CDSB" Value="CDSB"></asp:ListItem>
                                </asp:DropDownList>
                            </span><span id="spanFiltroProjetos" runat="server" class="spanFiltro">
                                <asp:Label ID="LblComboFiltro" Text="Projetos" runat="server" AssociatedControlID="cmbFiltroProjeto"></asp:Label>
                                <asp:DropDownList runat="server" ID="cmbFiltroProjeto" OnSelectedIndexChanged="CmbFiltro_SelectedIndexChanged"
                                    AutoPostBack="true">
                                    <asp:ListItem Text="Todos" Value="Todos"></asp:ListItem>
                                    <asp:ListItem Text="iMercado" Value="iMercado"></asp:ListItem>
                                    <asp:ListItem Text="Sinacor" Value="Sinacor"></asp:ListItem>
                                    <asp:ListItem Text="Site BVMF" Value="SiteBVMF"></asp:ListItem>
                                </asp:DropDownList>
                            </span>
                        </td>
                    </tr>
                </table>
            </div>
        </div>
    </div>
    <asp:GridView ID="GridFaturamentoAvaliacao" runat="server" Caption="Tasks em Avaliação" CaptionAlign="Left"
        AutoGenerateColumns="False" CellPadding="2"  Visible="False" AllowSorting="True"
        GridLines="None" OnDataBinding="Grid_DataBinding" OnRowDataBound="GridFaturamento_RowDataBound">
        <RowStyle BackColor="#E1ECFC" Font-Names="Verdana" Font-Size="X-Small" ForeColor="Black" />
        <Columns>
            <asp:TemplateField HeaderText="Task">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("Task") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="400px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Fornecedor">
                <ItemTemplate>
                    <asp:Label ID="Label2" runat="server" Text='<%# Bind("Factory") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Estimadas">
                <ItemTemplate>
                    <asp:Label ID="Label3" runat="server" Text='<%# Bind("PredictedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Utilizadas">
                <ItemTemplate>
                    <asp:Label ID="Label4" runat="server" Text='<%# Bind("UsedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            
            <asp:TemplateField HeaderText="Ínicio Realizado">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("EstimatedStart", "{0:dd/MM/yyyy}") %>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:BoundField DataField="EstimatedConclude" HeaderText="Término Realizado" 
                DataFormatString="{0:dd/MM/yyyy}" >
            
            <ControlStyle Width="75px" />
            </asp:BoundField>
            
            <asp:TemplateField HeaderText="Valor Estimado">
                <ItemTemplate>
                    <asp:Label ID="Label5" runat="server" Text='<%# Bind("EstimatedValue","{0:C}") %>'
                        CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor Utilizado">
                <ItemTemplate>
                    <asp:Label ID="Label6" runat="server" Text='<%# Bind("UsedValue","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Desvio">
                <ItemTemplate>
                    <asp:Label ID="Label7" runat="server" Text='<%# Bind("Deviation","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor/Hora">
                <ItemTemplate>
                    <asp:Label ID="Label8" runat="server" Text='<%# Bind("Hourly","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
        </Columns>
        <FooterStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <HeaderStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <AlternatingRowStyle BackColor="White" Font-Names="Verdana" Font-Size="X-Small" Wrap="False" />
    </asp:GridView>
    <br />    
    
    <asp:GridView ID="GridViewTaskDesenv" runat="server" Caption="Tasks em Desenvolvimento" CaptionAlign="Left"
        AutoGenerateColumns="False" CellPadding="2"  Visible="False" AllowSorting="True"
        GridLines="None" OnDataBinding="Grid_DataBinding" OnRowDataBound="GridFaturamento_RowDataBound">
        <RowStyle BackColor="#E1ECFC" Font-Names="Verdana" Font-Size="X-Small" ForeColor="Black" />
        <Columns>
            <asp:TemplateField HeaderText="Task">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("Task") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="400px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Fornecedor">
                <ItemTemplate>
                    <asp:Label ID="Label2" runat="server" Text='<%# Bind("Factory") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Estimadas">
                <ItemTemplate>
                    <asp:Label ID="Label3" runat="server" Text='<%# Bind("PredictedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Utilizadas">
                <ItemTemplate>
                    <asp:Label ID="Label4" runat="server" Text='<%# Bind("UsedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            
            <asp:TemplateField HeaderText="Ínicio Realizado">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("EstimatedStart", "{0:dd/MM/yyyy}") %>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:BoundField DataField="EstimatedConclude" HeaderText="Término Realizado" 
                DataFormatString="{0:dd/MM/yyyy}" >
            
            <ControlStyle Width="75px" />
            </asp:BoundField>
            
            <asp:TemplateField HeaderText="Valor Estimado">
                <ItemTemplate>
                    <asp:Label ID="Label5" runat="server" Text='<%# Bind("EstimatedValue","{0:C}") %>'
                        CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor Utilizado">
                <ItemTemplate>
                    <asp:Label ID="Label6" runat="server" Text='<%# Bind("UsedValue","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Desvio">
                <ItemTemplate>
                    <asp:Label ID="Label7" runat="server" Text='<%# Bind("Deviation","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor/Hora">
                <ItemTemplate>
                    <asp:Label ID="Label8" runat="server" Text='<%# Bind("Hourly","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
        </Columns>
        <FooterStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <HeaderStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <AlternatingRowStyle BackColor="White" Font-Names="Verdana" Font-Size="X-Small" Wrap="False" />
    </asp:GridView>
    
    <br />
    <asp:GridView ID="GridFaturamento" runat="server" Caption="Tasks Concluídas no Período"
        CaptionAlign="Left" AutoGenerateColumns="False" CellPadding="2" 
        Visible="False" AllowSorting="True" GridLines="None" OnDataBinding="Grid_DataBinding"
        OnRowDataBound="GridFaturamento_RowDataBound">
        <RowStyle BackColor="#E1ECFC" Font-Names="Verdana" Font-Size="X-Small" ForeColor="Black" />
        <Columns>
            <asp:TemplateField HeaderText="Task">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("Task") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="400px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Fornecedor">
                <ItemTemplate>
                    <asp:Label ID="Label2" runat="server" Text='<%# Bind("Factory") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Estimadas">
                <ItemTemplate>
                    <asp:Label ID="Label3" runat="server" Text='<%# Bind("PredictedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Horas Utilizadas">
                <ItemTemplate>
                    <asp:Label ID="Label4" runat="server" Text='<%# Bind("UsedHours") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            
            <asp:TemplateField HeaderText="Ínicio Realizado">
                <ItemTemplate>
                    <asp:Label ID="Label1" runat="server" Text='<%# Bind("EstimatedStart", "{0:dd/MM/yyyy}") %>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:BoundField DataField="EstimatedConclude" HeaderText="Término Realizado" 
                DataFormatString="{0:dd/MM/yyyy}" >
            
            <ControlStyle Width="75px" />
            </asp:BoundField>
            
            <asp:TemplateField HeaderText="Valor Estimado">
                <ItemTemplate>
                    <asp:Label ID="Label5" runat="server" Text='<%# Bind("EstimatedValue","{0:C}") %>'
                        CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor Utilizado">
                <ItemTemplate>
                    <asp:Label ID="Label6" runat="server" Text='<%# Bind("UsedValue","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Desvio">
                <ItemTemplate>
                    <asp:Label ID="Label7" runat="server" Text='<%# Bind("Deviation","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Valor/Hora">
                <ItemTemplate>
                    <asp:Label ID="Label8" runat="server" Text='<%# Bind("Hourly","{0:C}") %>' CssClass='<%# Eval("DeviationColor")%>'></asp:Label>
                </ItemTemplate>
                <ControlStyle Width="75px" />
            </asp:TemplateField>
        </Columns>
        <FooterStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <HeaderStyle BackColor="#CFDFF9" Font-Names="Verdana" Font-Size="X-Small" Font-Bold="True"
            HorizontalAlign="Left" />
        <AlternatingRowStyle BackColor="White" Font-Names="Verdana" Font-Size="X-Small" Wrap="False" />
    </asp:GridView>
    <div id="divAdendo" class="Adendo" runat="server" />
</asp:Content>
